$(document).ready(function(){
	setInterval(TopTimer,1000);
	$("#c_4 #c_4_tbar span").bind("mouseover",function(){
		var allSpan = $("#c_4 #c_4_tbar span");
		var span = $(this);
		allSpan.removeClass("check");
		span.addClass("check");
		var index = allSpan.index(span);
		var cnts = $(span).parent().parent().find(".cnt .cnt_t ul");
		cnts.hide();
		cnts.eq(index).show();
	});
	
	$("#keywords input").bind({
		"focus":function(){
			var input = $(this);
			if(input.val() == '请输入关键字')
			{
				$(this).val('').css("color","#000000");
			}
		},
		"blur":function(){
			var input = $(this);
			var word = '请输入关键字';
			if(input.val() == '')
			{
				$(this).val(word).css("color","#444444");
			}
		}
	});
});
function TopTimer()
{
	$("#time").html(TopTime());
}
function y2k(number)
    {
        return (number < 1000) ? number + 1900 : number;
    }
function TopTime()
{
	
	var now = new Date();
	var dd = now.getDate() , mt = now.getMonth() + 1 , yy = y2k(now.getYear()) , weekVal = now.getDay();
	if (weekVal==0)
		msg1="星期日";
	else if (weekVal==1)
		msg1="星期一"; 
	else if (weekVal==2)
		msg1="星期二";
	else if (weekVal==3)
		msg1="星期三";
	else if (weekVal==4)
		msg1="星期四";
	else if (weekVal==5)
		msg1="星期五";
	else if (weekVal==6)
		msg1="星期六";
	msg1 = yy+"年"+mt+"月"+dd+"日 " + msg1+"&nbsp;";
	var theHour = now.getHours();
	var theMin = now.getMinutes();
	var theSec = now.getSeconds();
	if (theHour<10)
	{
		theHour="0"+theHour
	}
	if(theMin<10)
	{
		theMin="0"+theMin
	}
	if(theSec<10)
	{
		theSec="0"+theSec
	}
	msg1 += theHour + ":" + theMin + ":" + theSec;
	return msg1;
}
